package com.kystar.muxplayer.protocol.code.get;

import android.util.Size;
import com.kystar.muxplayer.model.FreqType;
import com.kystar.muxplayer.protocol.CodeCmd;

public class CG83_OutPutInfo extends CodeCmd {
    private CG83_OutPutInfo() {
        super(CODE_OK);
    }

    @Override
    public byte getCode() {
        return (byte) 0x83;
    }

    public int getScreenSizeId() {
        return mResult[0]&0xff;
    }

    public Size getScreenSize() {
        return new Size(mResult[1]<<8&0xFF00 | mResult[2]&0xFF,
            mResult[3]<<8&0xFF00 | mResult[4]&0xFF);
    }

    public FreqType getFreqType() {
        return FreqType.values()[mResult[5]&0xff];
    }

    public static CG83_OutPutInfo create() {
        return new CG83_OutPutInfo();
    }
}
